<?
class sitemap{
	public static function protocolXml($map){
		$result="<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n";
		$result.="<urlset xmlns=\"http://www.google.com/schemas/sitemap/0.90\">\r\n";
		for($c=0;$c<count($map);$c++){
			$result.="\t<url>\r\n";
			foreach($map[$c] as $key=>$value){
				$result.="\t\t<$key>$value</$key>\r\n";
			}
			$result.="\t</url>\r\n";
		}
		$result.="</urlset>";
		header("Content-Type:text/xml");
		print($result);
		exit();
	}
}
?>